What is the origin of the letter ß?

ß is a consonant letter nowadays unique to the German language, where it is used to denote the voiceless alveolar sibilant [s] after long vowels and diphthongs. Yet, until the 19th century, ß was also in use in many other European languages like English, French, Danish, or Italian… (Question of the Week, 19.11.2012)